<%-- 
    Document   : prenotazioneAg
    Created on : 4-apr-2014, 14.39.19
    Author     : Salvo
--%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@page import="java.util.Iterator"%>
<%@page import="EntityPackage.Agenzia"%>
<%@page import="java.util.List"%>
<%@page contentType="text/html" pageEncoding="UTF-8"%>
<!DOCTYPE html>
<html>
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <link href="style-general.css" rel="stylesheet" type="text/css">
        <title>Prenotazione</title>
<script type='text/javascript'>

function toggleSubmit(nme,obj){
 var count=0;
 while(document.getElementById(nme+count)){
  document.getElementById(nme+count).style.display=obj.selectedIndex!=count?"none":"block"
  count++;
 }
}
</script>        
    </head>
    <body>
        <body>
        <div id="content-contact">
            <%--load the menu bar--%>
            <%@ include file="menuBar.jsp" %>
            <form id='data' action='Controller' method='post' accept-charset='UTF-8'>
            <div id="central">
                <td width="25%">Sceglia Agenzia</td>
                <td width="75%">         
                <p><select name="agenzia" onChange="toggleSubmit('d',this)">
                     <c:forEach items="${agenzieList}" var="agenzia">
                        <option value="${agenzia.idAgenzia}">${agenzia.nome}</option>
                     </c:forEach>
                    </select>
                </p> 
            <input type='hidden' name='hidden' value='agenzia' />        
            <input type='submit' name='Submit'  value='Avanti'/>
            </div>
            </form>
        </div>
    </body>
</html>
